<h1>Listing factories</h1>

<table>
  <tr>
    <th>Name</th>
    <th>Address</th>
    <th>Postalcode</th>
    <th>Tel</th>
    <th>Fax</th>
    <th>Reg address</th>
    <th>Website</th>
    <th>Mail</th>
  </tr>

<% for factory in @factories %>
  <tr>
    <td><%=h factory.name %></td>
    <td><%=h factory.address %></td>
    <td><%=h factory.postalcode %></td>
    <td><%=h factory.tel %></td>
    <td><%=h factory.fax %></td>
    <td><%=h factory.reg_address %></td>
    <td><%=h factory.website %></td>
    <td><%=h factory.mail %></td>
    <td><%= link_to 'Show', factory %></td>
    <td><%= link_to 'Edit', edit_factory_path(factory) %></td>
    <td><%= link_to 'Destroy', factory, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New factory', new_factory_path %>
